projects
/
emacs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6a3dadd
)
(face_for_char): Optimize for the case of no charset property.
author
Kenichi Handa
<handa@m17n.org>
Sun, 25 May 2008 11:02:11 +0000
(11:02 +0000)
committer
Kenichi Handa
<handa@m17n.org>
Sun, 25 May 2008 11:02:11 +0000
(11:02 +0000)
src/fontset.c
patch
|
blob
|
history
diff --git
a/src/fontset.c
b/src/fontset.c
index bafe1ca22559df0663bdbdb89372d715e54e2cbb..c61bcae88af1e4ab49443a8ac47fa1058f7b2371 100644
(file)
--- a/
src/fontset.c
+++ b/
src/fontset.c
@@
-908,6
+908,17
@@
face_for_char (f, face, c, pos, object)
id = XINT (CHARSET_SYMBOL_ID (charset));
}
}
+ if (id < 0)
+ {
+ struct font *font = face->ascii_face->font;
+
+ if (font && font->driver->encode_char (font, c) != FONT_INVALID_CODE)
+ return face->ascii_face->id;
+ font = face->font;
+ if (font && font->driver->encode_char (font, c) != FONT_INVALID_CODE)
+ return face->id;
+ }
+
rfont_def = fontset_font (fontset, c, face, id);
if (VECTORP (rfont_def))
{